package com.japstudy.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.japstudy.entity.Grade;
import com.japstudy.entity.Word;

@Repository
public interface IWordDao extends IBaseDao<Word> {
	
	List<Word> selectByNameLike(String wordName);

	List<Word> selectByGradeId(List<Grade> grades);

	List<Word> selectByGradeIdAndStar(@Param("list") List<Grade> grades, @Param("userId") String userId);
	
	List<Word> selectByGradeIdAndWrong(@Param("list") List<Grade> grades,@Param("userId") String userId);

	List<Word> selectAllStarWordByUserId(String userId);

	List<Word> selectAllWrongWordByUserId(String userId);

	List<Word> selectWrongByNameLike(@Param("wordName") String wordName, @Param("userId") String userId);

	List<Word> selectStarByNameLike(@Param("wordName") String wordName, @Param("userId") String userId);
}
